// 引入 request 文件
import request from '@/utils/request'

// 客户下拉列表
export const getWorkApi = (data = '') => {
  return request({
    url: '/system/work/list',
    method: 'post',
    data,
  })
}

// 获取存货下拉菜单数据
export const getproductsApi = (data = '') => {
  return request({
    url: '/system/work/products',
    method: 'post',
    data,
  })
}

// 获取外协商下拉菜单数据
export const getOutsourcingApi = (data = '') => {
  return request({
    url: '/system/work/outsourcing',
    method: 'post',
    data,
  })
}

// 上传图片api
export const designUpload = (data = '') => {
  return request({
    url: 'system/measurement/design',
    method: 'post',
    data,
  })
}
// 安装队
export const getListTeamsApi = (query = '') => {
  return request({
    url: '/system/teams/list',
    method: 'get',
    params: query,
  })
}

// 新增测量单
export const addMeasurement = (data) => {
  return request({
    url: '/system/measurement/add',
    method: 'post',
    data,
  })
}

// 查询测量单列表   designType 待设计 待审核 审核通过
export const listMeasurement = (data) => {
  return request({
    url: '/system/measurement/list',
    method: 'get',
    params: data,
  })
}

// 查询核算单列表
export const costingList = (data) => {
  return request({
    url: '/system/costing/list',
    method: 'get',
    params: data,
  })
}

// 设计师下拉
export const getdesignerMentsApi = (data = '') => {
  return request({
    url: '/system/work/designer',
    method: 'post',
    data,
  })
}

// 施工过程管理列表
export function processListApi(params) {
  return request({
    url: '/system/teams/processList',
    method: 'get',
    params,
  })
}

// 需施工订单查询
export function constructionListApi(params) {
  return request({
    url: '/system/teams/constructionList',
    method: 'get',
    params,
  })
}
// 安装队订单列表
export function constructionOrdersListApi(params) {
  return request({
    url: '/system/teams/constructionOrdersList',
    method: 'get',
    params,
  })
}
// 施工队接单接口
export function insertProcessApi(data = '') {
  return request({
    url: '/system/teams/insertProcess',
    method: 'post',
    data,
  })
}
//  施工队拒接 接口
export function rejectionApi(data = '') {
  return request({
    url: '/system/teams/rejection',
    method: 'post',
    data,
  })
}
//  施工队jidanjuejie 接口
export function acceptRejectionApi(params = '') {
  return request({
    url: '/system/teams/acceptRejection',
    method: 'get',
    params,
  })
}
//  查询施工过程图片
export function getProcessVOByIdApi(params = '') {
  return request({
    url: '/system/teams/getProcessVOById',
    method: 'get',
    params,
  })
}
//  施工过程上传图片
export function updateProcessApi(data = '') {
  return request({
    url: '/system/teams/updateProcess',
    method: 'post',
    data,
  })
}//  上传公费单
export function updatePayBillsApi(data = '') {
  return request({
    url: '/system/teams/updatePayBills',
    method: 'post',
    data,
  })
}//  上传验收单
export function updateAcceptanceApi(data = '') {
  return request({
    url: '/system/teams/updateAcceptance',
    method: 'post',
    data,
  })
}

